<template>
  <div>Event Component</div>
</template>

<script>
import store from '../store'

export default {
  name: "Event" ,
  props: ['id'],
  beforeRouteEnter(routeTo, routeFrom, next) {
    NProgress.start()
    store.dispatch('event/fetchEvent', routeTo.params.id).then(() => {
      NProgress.done()
      next()
    })
  },

}
</script>
